What Is OTA

An Over-The-Air update (or OTA update), or over-the-air programming (or OTA programming), is an update to an embedded system delivered through a wireless network, such as Wi-Fi or a cellular network. These embedded systems include mobile phones, tablets, set-top boxes, cars, and telecommunications equipment. OTA updates for vehicles and Internet of Things devices can also be called firmware over-the-air (FOTA). [Wikipedia]

OTAdrive FOTA Service

OTAdrive is a cloud service enabling you to manage your IoT devices. Its services include FOTA (Firmware OTA), Configuration, and Resources. Each service is designed to meet companies' requirements for mass IoT device production and future support.
Firmware OTA is the most important service you need for IoT device production in any count of devices. It allows you to upgrade your devices' firmware via the internet (OTAdrive website).
The OTAdrive lets you split your devices into seperate products, each with several device groups. Each device group could have a different firmware version, configuration, and resources.

ota-device-group-organization

Every device should have a unique serial number. Usually, the device's MAC address is used as its serial number. When devices ask the server for the newer version, it sends its serial number to the OTAdrive. The OTAdrive will return the firmware file of the group you've assigned. So, you can change the firmware of all devices in a group with just a single click. This feature lets you upgrade your devices safely with a limited count.
For example, if you've sold 2000 units of a product and a bug is reported, You can't take the risk of updating 2000 devices together. The best way is to upgrade ten devices first, and if everything is well, you can upgrade the next group of 300 devices; if everything is still good, then you can upgrade the rest of the devices.

ota-device-groups

Workflow Diagram

Every device should send its serial number, API key, and current firmware version to the OTAdrive when it asks for the new firmware. OTAdrive checks these three parameters to answer the device.

  • ❌ If the API key is wrong or the device is not Verified, it replies to the device with error code 401 (Unauthorize access).

  • ❌ If the API key is correct and the device is Verified, it searches for the device group to which it belongs. If no firmware has been assigned to the group, it replies to the device with error code 404 (No firmware available).

  • ❌ If the API key is correct and the device is Verified, it compares the device's firmware version with the firmware assigned to the group the device belongs to. If they are the same, it replies to the device with error code 304 (Same firmware, Already up-to-date).

  • ✅ If the API key is correct and the device is Verified, it compares the device's firmware version with the firmware assigned to the group the device belongs to. If they aren't the same, it replies to the device with the group's firmware file, and the device starts the download and upgrade procedure.

The following diagram shows how it work.

ota-device-groups